﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data;
using QuanLyKhachSanDAO.DTO;

namespace QuanLyKhachSanDAO.DAO
{
    public class HoaDonDAO
    {
        public  DataTable LapHoaDon(HoaDonDTO hd)
        {
            DataTable tb = new DataTable();
            string sql = string.Format("insert into hoadon values('{0}',{1},{2}); select @@identity", hd.NgayLapHoaDon, hd.TriGia, hd.MaKhachHang);
            DataProvider ds = new DataProvider();
            tb = ds.ExecuteQuery(sql);
            return tb;
        }
    }
}